<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class ShopGoodsTypes extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
      Schema::create('shop_goods_types', function (Blueprint $table) {
          $table->increments('id');               // id
          $table->string('type_name', 50);            // 分类名
          $table->Integer('pid')->unsigned();     // 父类id
          $table->string('path', 100)->default('0,');
          $table->timestamps();
      });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('shop_goods_types');
    }
}
